#include "userfun.h"

/*频率读取函数

//*******频率读取*******  用定时器1
	if (frequency_time_flag == 1)
	{
		frequency_time_flag = 0;
		//频率读取
		TR0 = 0;
		Frequency_Data = TH0*256+TL0;
		Frequency_Data = Frequency_Data * 2;
		TL0=0;
		TH0=0;
		TR0=1;
		
		uc_PCF_ADC_0x03_Data = PCF8591_ADC_Read(0x03);//和频率读取放在一起，先少定义一个标志位，偷个懒
	}
*/

void Jidianqi_ON(void)
{
	P0 = 0x10;P2 = 0xA0;
	
}

void Jidianqi_OFF(void)
{
	P0 = 0x00;P2 = 0xA0;
	
}	

void Buzzer_ON(void)
{
	P0 = 0x40;P2 = 0xA0;
	
}
void Buzzer_OFF(void)
{
	P0 = 0x00;P2 = 0xA0;
	
}




